package com.ruoyi.manage.cms.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.utils.ListUtil;
import com.ruoyi.manage.cms.service.IHbZcfgService;
import com.ruoyi.manage.cms.domain.HbZcfg;
import com.ruoyi.manage.cms.mapper.HbZcfgMapper;
import org.springframework.stereotype.Service;


/**
 * 政策法规Service业务层处理
 *
 * @author ruoyi
 * @date 2025-07-19
 */
@Service
public class HbZcfgServiceImpl extends ServiceImpl<HbZcfgMapper, HbZcfg> implements IHbZcfgService {


    @Override
    public HbZcfg queryGetById(String id){
        HbZcfg hbZcfg = this.getById(id);
        return hbZcfg;
    }

    /**
     * 新增政策法规
     *
     * @param hbZcfg 政策法规
     * @return 结果
     */
    @Override
    public boolean addHbZcfg(HbZcfg hbZcfg){
        boolean save =this.save(hbZcfg);
        return save;
    }

    /**
     * 修改政策法规
     *
     * @param hbZcfg 政策法规
     * @return 结果
     */
    @Override
    public boolean updateHbZcfg(HbZcfg hbZcfg){
        return this.updateById(hbZcfg);
    }

    /**
     * 批量删除政策法规
     *
     * @param ids 需要删除的政策法规主键
     * @return 结果
     */
    @Override
    public boolean deleteHbZcfgByIds(String[] ids){
        return this.removeByIds(ListUtil.toList(ids));
    }

}
